package com._520it.crm.query;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Getter;
import lombok.Setter;
import org.apache.commons.lang.StringUtils;

import java.util.Date;

@Setter@Getter
public class PaymentCheckQueryObject extends QueryObject{
    private String everyNo; //任何种类的单号
    private Integer issue; //期次
    private String clientName;  //姓名
    private Integer paymentType = -1 ;  //缴费类型
    private Long productId = -1L;  //产品id
    private Integer state = -1;  //保单状态
    private Long organizationId = -1L;   //承保机构id
    @JsonFormat(pattern = "yyyy-MM-dd",timezone ="GMT+8" )
    private Date minDate;//起始时间
    @JsonFormat(pattern = "yyyy-MM-dd",timezone ="GMT+8" )
    private Date maxDate;//截止时间

    public String getEveryNo(String everyNo){
        return StringUtils.isNotBlank(everyNo)?everyNo:null;
    }

    public String getClientName(String clientName){
        return StringUtils.isNotBlank(clientName)?clientName:null;
    }
}
